package cn.jobstart.task;

import cn.jobstart.modelExt.SpiderMonitorExt;
import cn.jobstart.pubInter.AbstractTask;
import cn.jobstart.spider.service.ISpiderService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

/**
 * @author sunke
 * @version 1.0
 * @Description 51job
 * @date 2023-09-14 16:21
 */
@EnableScheduling
@Slf4j
@Component
public class NbrcJobTask extends AbstractTask {


    @Resource
    private ISpiderService spiderService;

    //@Scheduled(cron = "0 0/1 * * * ?")
    @Override
    public void run() {

        try {
            spiderService.startNbrcJob(new SpiderMonitorExt());
        } catch (Exception e) {

        }

    }
}
